<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <title>会员权益</title>
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="../../../../elementUI/index.css">
  <link rel="stylesheet" href="../../../../css/index.css">
</head>

<body>
  <div id="app" class="minWidth">
    <el-form :model="form" :rules="rules" ref="contract" inline-message="true" style="width: 100%">
      <el-input v-model.trim="form.Enterprise_Info_SerialNumber" v-show="false"></el-input>
      <el-input v-model.trim="form.Industry_SubCategory_SerialNumber" v-show="false"></el-input>
      <el-input v-model.trim="form.Industry_Category_SerialNumber" v-show="false"></el-input>
      <div class="table_titel">
        <div class="titel">会员权益</div>
      </div>
      <el-descriptions :column="3" border size="small">
        <el-descriptions-item label="权益名称">
          <el-form-item prop="Member_Rights_Name">
            <el-input v-model.trim="form.Member_Rights_Name" placeholder="请输入权益名称"></el-input>
          </el-form-item>
        </el-descriptions-item>
        <el-descriptions-item label="最低预付款">
          <el-form-item prop="Prepayment">
            <el-input type="numBer" v-model.trim="form.Prepayment" placeholder="请输入最低预付款"></el-input>
          </el-form-item>
        </el-descriptions-item>
        <el-descriptions-item label="折扣价(几折)">
          <el-form-item prop="Discount">
            <el-input type="numBer" v-model.trim="form.Discount" placeholder="请输入折扣价"></el-input>
          </el-form-item>
        </el-descriptions-item>
        <!-- <el-descriptions-item label="小程序">
          <el-form-item prop="App_ID">
            <el-select v-model.trim="form.App_ID" placeholder="请选择小程序" filterable style="width: 100%">
              <el-option v-for="(item,index) in shop" :key="index" :label="item.App_Name"
                :value="item.App_ID"></el-option>
            </el-select>
          </el-form-item>
        </el-descriptions-item> -->
        <el-descriptions-item label="权益头像">
          <el-form-item prop="pic">
            <div class="preview" v-show="form.pic">
              <el-image class="el-upload-list__item-thumbnail" style="width: 148px; height: 148px" :src="form.pic"
                fit="contain"></el-image>
              <span class="el-upload-list__item-actions">
                <span @click="handlePictureCardPreview(form.pic)"><i class="el-icon-zoom-in"></i></span>
                <span @click="handleRemove('front')"><i class="el-icon-delete"></i></span>
              </span>
            </div>
            <el-upload v-show="!form.pic" class="upload-demo" :show-file-list="false" list-type="picture-card" action=""
              accept="image/*" :before-upload="uploadFront">
              <i slot="default" class="el-icon-plus"></i>
              <div class="el-upload__tip" slot="tip">上传正方形图片，且大小不超过120k</div>
            </el-upload>
          </el-form-item>
        </el-descriptions-item>
      </el-descriptions>
      <div class="table_titel">
        <div class="titel">所属小程序</div>
        <div class="operation">
          <el-button type="primary" size="small" @click="add_member_rights_appid">新增</el-button>
          <el-button type="danger" size="small" @click="remove_member_rights_appid">删除</el-button>
        </div>
      </div>
      <el-descriptions :column="1" border size="small" v-for="(item,index) in form.Children.member_rights_appid"
        :key="item.key">
        <el-descriptions-item label="小程序">
          <el-form-item>
            <el-select v-model.trim="item.App_ID" placeholder="请选择小程序" filterable style="width: 100%">
              <el-option v-for="(item,index) in shop" :key="index" :label="item.App_Name"
                :value="item.App_ID"></el-option>
            </el-select>
          </el-form-item>
        </el-descriptions-item>
      </el-descriptions>
      <el-dialog :visible.sync="dialogVisible">
        <img width="100%" :src="dialogImageUrl" alt="">
      </el-dialog>
      <el-form-item class="form-operation">
        <el-button @click="window.history.back()">返回</el-button>
        <el-button type="primary" :loading="loading" @click="submitForm('contract')">提交</el-button>
      </el-form-item>
    </el-form>
  </div>
  <script type="text/javascript" src="../../../../js/jquery-3.6.0.min.js"></script>
  <script type="text/javascript" src="../../../../js/jquery.cookie.js"></script>
  <script type="text/javascript" src="../../../../js/vue.min.js"></script>
  <script type="text/javascript" src="../../../../elementUI/index.js"></script>
  <script type="text/javascript" src="../../../../js/utils.js"></script>
  <script type="text/javascript" src="../../../../js/compressor.js"></script>
  <script type="text/javascript" src="../../../../js/ID_Validity.js"></script>
  <script type="text/javascript" src="./js/Add.js"></script>
</body>

</html>